Let G be a group and H be a nonempty subset.  Then H is a subgroup of G if ab is in H whenever a and b are in H and a-1 is in H whenever a is in H.